#!/bin/sh

BASEDIR=${HOME}/Projects/SimGear-0.3
SRCDIR=${BASEDIR}/SimGear
DOXYDIR=${BASEDIR}/doxy
WEBDIR=${BASEDIR}/www/doxygen

# Clean up the old

cd ${DOXYDIR} || exit
/bin/rm -rf html latex man rtf


# Generate the new

cd ${SRCDIR} || exit
doxygen Doxyfile


# Clean and copy to the web tree

\rm -rf ${WEBDIR}
mkdir -p ${WEBDIR}
cd ${DOXYDIR}/html || exit
tar cf - * | (cd ${WEBDIR}; tar xvf -)


# Mirror reminder

echo
echo "Don't forget to run ${BASEDIR}/admin/mirror-www"
